<!DOCTYPE html>
<html>

  <head>
    <meta charset="utf-8">
    <title>技术交底确认</title>
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <link href="../../../css/mui.min.css" rel="stylesheet" />
    <link href="../css/common.css" rel="stylesheet" />
    <style>
      .mui-content>.mui-table-view:first-child {
        margin-top: 1px;
      }
      
      .icon {
        width: 35px;
        vertical-align: middle;
        margin-right: 10px;
      }
      
      .mui-table-view-cell:after {
        left: 45px;
        height: 1px;
      }
      
      .mui-table-view-cell {
        padding: 11px 11px 11px 11px;
      }
      
      .mui-table-view:after {
        left: 45px;
      }
      
      .mui-bar {
        background-color: #0082E6;
      }
      
      .uls {
        padding: 40px 20px;
      }
      
      .mui-table-view:after {
        height: 0;
      }
      
      .head_top {
        padding: 30px 0;
        overflow: hidden;
      }
      
      .titles {
        /* font-weight: bold; */
        margin-bottom: 24px;
      }
      
      .rows {
        display: flex;
      }
      
      .img_s {
        float: left;
        width: 18px;
        height: 18px;
        background: url(../img/word.png) no-repeat;
        background-size: 100%;
        margin: auto 0;
      }
      
      .rows {
        height: 50px;
        background: #D4E6FF;
        border-radius: 5px;
        line-height: 50px;
        padding-left: 16px;
        margin-bottom: 24px;
      }
      
      .bocks {
        padding: 0 5px;
      }
      
      .areas {
        background-color: #F1F3F7;
      }
      
      .signs {
        width: 160px;
        height: 160px;
        background-color: #D4E6FF;
        border: solid 2px #3188FE;
        border-radius: 5px;
      }
      
      .submits {
        width: 100%;
        margin-top: 30px;
        height: 4 0px;
        border-radius: 30px;
      }
            
            /* 卡片样式 -- begin */
            .mui-card {
              border-radius: 5px;
              box-shadow: none;
            }
            
            .lists {
              padding: 10px;
            }
            
            .lists li {
              margin-bottom: 15px;
              font-size: 14px;
              display: flex;
              justify-content: space-between;
            }
            
            .lists li .left_name {
              color: #9098ab;
              white-space: nowrap;
            }
            
            .lists li .right_name {
              color: #333333;
              float: right;
            }
            
            .btntxt {
              width: 100%;
              text-align: right;
              font-size: 14px;
              padding-right: 20px;
              color: #3188fe;
            }
            /* 卡片样式 -- end */
    </style>
  </head>

  <body class="bg-white">
    <header class="mui-bar mui-bar-nav">
      <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left text-white"></a>
      <h1 class="mui-title">技术交底确认</h1>
    </header>
    <div class="mui-content page-wrap" id="container" v-cloak>
      <ul class="mui-table-view uls page-scroll">
        <li class="lis">
          <div class="des">
            <div class="titles"><span>技术交底确认书</span></div>
            <div class="rows" id="download"><span class="img_s"></span><span class="bocks">技术交底确认书.dox</span></div>
          </div>
                    
                    <div class="mui-card-footer">
                      <!-- <a class="mui-navigate-right btntxt" @tap="toTask(item)">任务列表</a> -->
                      <a class="mui-navigate-right btntxt" @click="isExpend=!isExpend"
                        >查看项目详情</a
                      >
                    </div>
                    <div v-show="isExpend">
                    <!-- 1、项目信息 -->
                    <div class="titles"><span>项目信息</span></div>
                    <div
                      class="mui-card card_content"
                        
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">创建人：</span>
                          <span class="right_name"
                            >{{project.createName}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">创建时间：</span>
                          <span class="right_name"
                            >{{project.createTime}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">检修项目：</span>
                          <span class="right_name">{{project.name}}</span>
                        </li>
                            
                            <li class="lis">
                              <span class="left_name">区域：</span>
                              <span class="right_name">{{project.areaName}}</span>
                            </li>
                            <li class="lis">
                              <span class="left_name">场站：</span>
                              <span class="right_name">{{project.stationName}}</span>
                            </li>
                            <li class="lis">
                              <span class="left_name">作业类型：</span>
                              <span class="right_name">{{project.oneLevelTaskTypeName}}</span>
                            </li>
                        <li class="lis">
                          <span class="left_name">计划开始时间：</span>
                          <span class="right_name"
                            >{{ formatDate(project.starttime, 'yyyy-MM-dd')}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">计划结束时间：</span>
                          <span class="right_name"
                            >{{ formatDate(project.endtime, 'yyyy-MM-dd')}}</span
                          >
                        </li>
                            <li class="lis">
                              <span class="left_name">负责人：</span>
                              <span class="right_name">{{project.leaderName}}</span>
                            </li>
                            <li class="lis">
                              <span class="left_name">审批人：</span>
                              <span class="right_name">{{project.approver}}</span>
                            </li>
                      </ul>
                    </div>
                    </div>
                    
                    <!-- 2、风险列表 -->
                    <div class="titles"><span>风险列表</span></div>
                    <div
                        v-if="project.sensitiveHazardList.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.sensitiveHazardList"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">风险描述：</span>
                          <span class="right_name"
                            >{{item.riskNode}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">措施：</span>
                          <span class="right_name">{{item.jobProject}}</span>
                        </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.sensitiveHazardList.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 3、选择内部人员 -->
                    <div class="titles"><span>选择内部人员</span></div>
                    <div
                        v-if="project.innerPersons.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.innerPersons"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">姓名：</span>
                          <span class="right_name"
                            >{{item.fullname}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">公司：</span>
                          <span class="right_name">{{item.company}}</span>
                        </li>
                            <li class="lis">
                              <span class="left_name">联系方式：</span>
                              <span class="right_name">{{item.contact}}</span>
                            </li>
                            <li class="lis">
                              <span class="left_name">工号：</span>
                              <span class="right_name">{{item.jobNumber}}</span>
                            </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.innerPersons.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 4、选择外部人员 -->
                    <div class="titles"><span>选择外部人员</span></div>
                    <div
                        v-if="project.outerPersons.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.outerPersons"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">姓名：</span>
                          <span class="right_name"
                            >{{item.fullname}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">公司：</span>
                          <span class="right_name">{{item.company}}</span>
                        </li>
                            <li class="lis">
                              <span class="left_name">联系方式：</span>
                              <span class="right_name">{{item.contact}}</span>
                            </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.outerPersons.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 5、车辆信息 -->
                    <div class="titles"><span>车辆信息</span></div>
                    <div
                        v-if="project.projectCars.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.projectCars"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">车牌号：</span>
                          <span class="right_name"
                            >{{item.carLicense}}</span
                          >
                        </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.projectCars.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 6、工序 -->
                    <div class="titles"><span>工序</span></div>
                    <div
                        v-if="project.projectWps.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.projectWps"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">工序编号：</span>
                          <span class="right_name"
                            >{{item.code ||item.wpCode}}</span
                          >
                        </li>
                            <li class="lis">
                              <span class="left_name">作业项目：</span>
                              <span class="right_name"
                                >{{item.jobProject}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">作业方法：</span>
                              <span class="right_name"
                                >{{item.jobMethod}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">工器具：</span>
                              <span class="right_name"
                                >{{getName(item.utensil)}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">备件：</span>
                              <span class="right_name"
                                >{{getName(item.sparePart)}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">耗材：</span>
                              <span class="right_name"
                                >{{getName(item.consumables)}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">标准：</span>
                              <span class="right_name"
                                >
                                    <!-- {{ $utils.inputShowText(item, dicts) }} -->
                                    <div v-if="item.input.length == 0">无</div>
                                    <div v-for="(item1, i) in item.input" :key="item1.id">
                                        <span v-if="item.input.length > 1">{{ i + 1 }}、</span>
                                        {{ item1.name }}&nbsp;参考值&nbsp;{{inputShowText(item1,dicts)}}
                                    </div>
                                    </span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">是否必选：</span>
                                <span class="right_name">{{ item.isMust ? '是' : '否' }}</span>
                            </li>
                            <li class="lis">
                              <span class="left_name">标签：</span>
                              <span class="right_name"
                                >{{ dicts.id.wpTag[item.tagId] && dicts.id.wpTag[item.tagId].code }}</span
                              >
                                
                                
                            </li>
                            <li class="lis">
                              <span class="left_name">选择人员：</span>
                              <span class="right_name"
                                >{{item.fullname}}</span
                              >
                            </li>
                            
                            
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.projectWps.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 7、工器具清单 -->
                    <div class="titles"><span>工器具清单</span></div>
                    <div
                        v-if="project.utensil.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.utensil"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">编号：</span>
                          <span class="right_name"
                            >{{item.id}}</span
                          >
                        </li>
                            <li class="lis">
                              <span class="left_name">工器具名称：</span>
                              <span class="right_name"
                                >{{item.name}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">规格/型号：</span>
                              <span class="right_name"
                                >{{item.materialSpec}}</span
                              >
                            </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.utensil.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 8、备品备件 -->
                    <div class="titles"><span>备品备件</span></div>
                    <div
                        v-if="project.sparePart.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.sparePart"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">编号：</span>
                          <span class="right_name"
                            >{{item.id}}</span
                          >
                        </li>
                            <li class="lis">
                              <span class="left_name">备品备件名称：</span>
                              <span class="right_name"
                                >{{item.name}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">规格/型号：</span>
                              <span class="right_name"
                                >{{item.materialSpec}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">数量：</span>
                              <span class="right_name"
                                >{{item.quantity}}</span
                              >
                            </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.sparePart.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 9、耗材 -->
                    <div class="titles"><span>耗材</span></div>
                    <div
                        v-if="project.consumables.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.consumables"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">编号：</span>
                          <span class="right_name"
                            >{{item.id}}</span
                          >
                        </li>
                            <li class="lis">
                              <span class="left_name">耗材名称：</span>
                              <span class="right_name"
                                >{{item.name}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">规格/型号：</span>
                              <span class="right_name"
                                >{{item.materialSpec}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">数量：</span>
                              <span class="right_name"
                                >{{item.quantity}}</span
                              >
                            </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.consumables.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    <!-- 10、附件 -->
                    <div class="titles"><span>附件</span></div>
                    <div
                        v-if="project.projectFiles.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in project.projectFiles"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                                <div class="rows" style="width:100%;"><span class="img_s"></span><span class="bocks" @click="download(item.filePath)">{{item.filename}}</span></div>
                        </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="project.projectFiles.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    
                    
                    <!-- 11、技术交底确认-->
                    <div class="titles"><span>技术交底确认</span></div>
                    <div
                        v-if="technicalConfirms.length>0"
                      class="mui-card card_content"
                        v-for="(item,index) in technicalConfirms"
                        :key="index"
                        v-cloak
                    >
                    <div class="mui-card-content">
                      <ul class="mui-table-view lists">
                        <li class="lis">
                          <span class="left_name">序号：</span>
                          <span class="right_name"
                            >{{index+1}}</span
                          >
                        </li>
                        <li class="lis">
                          <span class="left_name">人员名称：</span>
                          <span class="right_name"
                            >{{item.userName}}</span
                          >
                        </li>
                            <li class="lis">
                              <span class="left_name">状态：</span>
                                <span v-if="item.status == 1" class="right_name">已确认</span>
                                <span v-if="item.status == 2" class="right_name">未确认</span>
                                <span v-if="item.status == 3" class="right_name">补签</span>
                            </li>
                            <li class="lis">
                              <span class="left_name">签字时间：</span>
                              <span class="right_name"
                                >{{ item.status == 2 ? '' : item.updateTime}}</span
                              >
                            </li>
                            <li class="lis">
                              <span class="left_name">备注：</span>
                              <span class="right_name"
                                >{{item.remarks}}</span
                              >
                            </li>
                      </ul>
                    </div>
                    </div>
                    <div class="mui-card-content" v-if="technicalConfirms.length==0">
                        <ul class="mui-table-view lists">
                          <li class="lis">
                            <span class="left_name"></span>
                            <span class="right_name"
                              >暂无数据</span
                            >
                          </li>
                    </div>
                    </div>
                    
                    
          <div class="titles"><span>其他备注</span></div>
          <textarea name="" class="areas" cols="30" rows="6" id="textarea" maxlength="200"></textarea>
          <div class="titles"><span>签字(必填)</span></div>
          <div class="signs br" id="sign">
            <img id="signImg" style="width: 100%;height: 100%;display: none;" src="" />
          </div>
        </li>
      </ul>
      <div class="fixed-btn">
        <button type="button" class="mui-btn mui-btn-primary" id="submit">提交</button>
      </div>
    </div>
    <script src="../../../js/mui.js"></script>
    <script src="../js/mkeyplus.base.js" type="text/javascript" charset="utf-8"></script>
    <script src="../../../js/jquery-1.7.2.min.js"></script>
        <script src="../../../js/vue.js" type="text/javascript" charset="utf-8"></script>
        <script
          src="../js/sqlite.js"
          type="text/javascript"
          charset="utf-8"
        ></script>

    <script type="text/javascript">
      mui.init()
      let projectId, fileId;

            
      if(window.plus) {
        plusready();
      } else {
        document.addEventListener('plusready', plusready, false);
      }

      function plusready() {
        var self = plus.webview.currentWebview();
        console.log(22,self)
        projectId = self.projectId
                mui.baseApp
                  .getDict(["valueUnit", "valueType", "inputSymbol", "wpTag"])
                  .then((res) => {
                    console.log("-------------")
                    console.log(res)
                    vm.dicts = res
                  })
                getProject(projectId)
      }
            
            var vm = new Vue({
              el: "#container",
              data: {
                    dicts:{},
                    isExpend:false,
                project:{
                        sensitiveHazardList:[], // 风险列表
                        innerPersons:[], // 内部人员
                        outerPersons:[], // 外部人员
                        projectCars:[], // 车辆信息
                        projectWps:[], // 工序 
                        utensil:[], // 工器具清单
                        sparePart:[], // 备品备件
                        projectFiles:[], // 附件
                        consumables:[] // 耗材
                    }, // 项目信息
                    technicalConfirms:[] // 技术交底确认
              },
              created: function () {
                //        getProject(page)
                //        getTaskList(donePage)
              },
              methods: {
                formatDate(tmp, fmt) {
                  return mui.baseApp.formatDate(tmp, fmt)
                },
                    download(filePath){
                        plus.nativeUI.showWaiting('加载中')
                        mui.baseApp.download(mui.baseApp.serverUrl+filePath, 'disclose/' + filePath, function(res) {
                          plus.nativeUI.closeWaiting()
                          plus.runtime.openFile(res.filename, {}, function(e) {
                            console.log('打开失败');
                          });
                        }, function() {
                          plus.nativeUI.closeWaiting()
                        })
                    },
                    getName(arr) {
                        if (!arr) {
                            return '无'
                        }
                        if (arr.length == 0) {
                            return '无'
                        }
                        return arr
                            .map(item => {
                                return item.name
                            })
                            .join('、')
                    },
                    inputShowText(obj, dict) {
                      // console.log(obj)
                      let type = dict.id.valueType[obj.typeId].value // 类型
                      if (type == "text") {
                        return obj.value
                      } else if (type == "img") {
                        return "无"
                      } else if (type == 'boolean') {
                        return '是否'
                      } else {
                        let unit = dict.id.valueUnit[obj.unitId].value // 单位
                        let symbol = dict.id.inputSymbol[obj.typeSubId].value // 符号
                        let valueArr = obj.value.split(",")
                        let showText = ""
                        switch (symbol) {
                          case ">":
                            showText = ">" + valueArr[0] + unit
                            break
                          case "≥":
                            showText = "≥" + valueArr[0] + unit
                            break
                          case "<":
                            showText = "<" + valueArr[0] + unit
                            break
                          case "≤":
                            showText = "≤" + valueArr[0] + unit
                            break
                          case "=":
                            showText = "=" + valueArr[0] + unit
                            break
                          case "!=":
                            showText = "!=" + valueArr[0] + unit
                            break
                          case "()":
                            showText =
                              ">" + valueArr[0] + unit + "  " + "<" + valueArr[1] + unit
                            break
                          case "[]":
                            showText =
                              "≥" + valueArr[0] + unit + "  " + "≤" + valueArr[1] + unit
                            break
                          case "(]":
                            showText =
                              ">" + valueArr[0] + unit + "  " + "≤" + valueArr[1] + unit
                            break
                          case "[)":
                            showText =
                              "≥" + valueArr[0] + unit + "  " + "<" + valueArr[1] + unit
                            break
                          case ")(":
                            showText =
                              "<" + valueArr[0] + unit + "  " + ">" + valueArr[1] + unit
                            break
                          case "][":
                            showText =
                              "≤" + valueArr[0] + unit + "  " + "≥" + valueArr[1] + unit
                            break
                          case ")[":
                            showText =
                              "<" + valueArr[0] + unit + "  " + "≥" + valueArr[1] + unit
                            break
                          case "](":
                            showText =
                              "≤" + valueArr[0] + unit + "  " + ">" + valueArr[1] + unit
                            break
                          default:
                            showText = obj.value + unit
                            break
                        }
                        return showText
                      }
                    }
              },
            })
            
            // 获取 项目详情
            function getProject(projectId) {
              plus.nativeUI.showWaiting("加载中...")
              mui.baseApp.httpRequst(
                "get",
                "/app/api/technicalConfirms/details/"+projectId,{},
                function (data) {
                  console.log(data,'获取项目数据')
                  plus.nativeUI.closeWaiting()
                        
                  vm.project = data.data.project // 项目信息
                        vm.project.innerPersons = data.data.project.projectUsers.filter(p=>p.userType==2) // 内部人员
                        vm.project.outerPersons = data.data.project.projectUsers.filter(p=>p.userType==1) // 外部人员
                        
                        vm.technicalConfirms = data.data.technicalConfirms // 技术交底确认列表信息
                },
                function () {
                  plus.nativeUI.closeWaiting()
                  console.log("获取数据失败")
                }
              )
            }

      $(document).ready(function() {
        let height = document.documentElement.clientHeight
        //防止软键盘弹出底部按钮顶上来
        $(".mui-content").css('height', height + 'px')
      })
      //跳转签名
      $("#sign").click(function() {
        mui.baseApp.openWindow('../common/sign.html')
      })

      //提交
      $("#submit").on("tap", function() {
        let params = {
          fileId: fileId,
          projectId: projectId,
          remarks: $("#textarea").val()
        }
        if(!params.fileId) {
          mui.toast('请签名')
          return
        }
        plus.nativeUI.showWaiting("提交中")
        mui.baseApp.httpRequst('put', '/app/api/project/execution/technicalConfirm', params, function(res) {
          console.log(res)
          plus.nativeUI.closeWaiting()
          mui.toast("提交成功")
          var opener = plus.webview.currentWebview().opener();
          mui.fire(opener, 'back', {});
          mui.back()
        }, function() {
          plus.nativeUI.closeWaiting()
        })
      })
      $("#download").click(function() {
        plus.nativeUI.showWaiting('加载中')
        mui.baseApp.download('/app/api/project/execution/archive/' + projectId, 'disclose/' + projectId + '/技术交底.docx', function(res) {
          plus.nativeUI.closeWaiting()
          plus.runtime.openFile(res.filename, {}, function(e) {
            console.log('打开失败');
          });
        }, function() {
          plus.nativeUI.closeWaiting()
        })
      })
      window.addEventListener('sign', function(event) {
        let data = event.detail
        fileId = data.fileId
        $("#signImg").attr('src', data.img)
        $("#signImg").show()
      });
    </script>
  </body>

</html>